package com.hundsun.cprs.yyt.web.vo.excel;

import com.hundsun.cprs.yyt.service.trade.domain.TradeEntrust;
import com.hundsun.cprs.yyt.service.trade.enums.EnumTradeStatus;
import com.hundsun.cprs.yyt.util.MoneyUtils;

import java.util.Date;

public class TradeEntrustAuditExportVo {
    /**
     * 委托编号
     */
    private Long entrustNo;

    /**
     * 关联订单编号
     */
    private String orderSn;

    /**
     * 新老会员委托标签
     *
     * */
    private String entrustTagDesc;

    /**
     * 用户姓名
     */
    private String userName;

    /**
     * 资金账号
     */
    private String fundAccount;

    /**
     * 商品代码
     */
    private String goodsCode;

    /**
     * 委托价格
     */
    private String entrustPrice;

    /**
     * 委托数量
     */
    private Long entrustAmount;

    /**
     * 委托大类状态 {@link EnumTradeStatus}
     */
    private String statusDesc;

    /**
     * 申请时间
     */
    private Date gmtCreate;

    public TradeEntrustAuditExportVo(TradeEntrust entrust){
        this.entrustNo = entrust.getEntrustNo();
        this.orderSn = entrust.getOrderSn();
        this.entrustTagDesc = entrust.getEntrustTag()==1?"老":"新";
        this.userName = entrust.getUserName();
        this.fundAccount = entrust.getFundAccount();
        this.goodsCode = entrust.getGoodsCode();
        this.entrustPrice = MoneyUtils.getMoneyFormatFen(entrust.getEntrustPrice());
        this.entrustAmount = entrust.getEntrustAmount();
        this.statusDesc = EnumTradeStatus.indexByValue(entrust.getStatus()).getDesc();
        this.gmtCreate = entrust.getGmtCreate();
    }

    public Long getEntrustNo() {
        return entrustNo;
    }

    public void setEntrustNo(Long entrustNo) {
        this.entrustNo = entrustNo;
    }

    public String getOrderSn() {
        return orderSn;
    }

    public void setOrderSn(String orderSn) {
        this.orderSn = orderSn;
    }

    public String getEntrustTagDesc() {
        return entrustTagDesc;
    }

    public void setEntrustTagDesc(String entrustTagDesc) {
        this.entrustTagDesc = entrustTagDesc;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public String getFundAccount() {
        return fundAccount;
    }

    public void setFundAccount(String fundAccount) {
        this.fundAccount = fundAccount;
    }

    public String getGoodsCode() {
        return goodsCode;
    }

    public void setGoodsCode(String goodsCode) {
        this.goodsCode = goodsCode;
    }

    public String getEntrustPrice() {
        return entrustPrice;
    }

    public void setEntrustPrice(String entrustPrice) {
        this.entrustPrice = entrustPrice;
    }

    public Long getEntrustAmount() {
        return entrustAmount;
    }

    public void setEntrustAmount(Long entrustAmount) {
        this.entrustAmount = entrustAmount;
    }

    public String getStatusDesc() {
        return statusDesc;
    }

    public void setStatusDesc(String statusDesc) {
        this.statusDesc = statusDesc;
    }

    public Date getGmtCreate() {
        return gmtCreate;
    }

    public void setGmtCreate(Date gmtCreate) {
        this.gmtCreate = gmtCreate;
    }
}
